import time
from selenium import webdriver
from selenium.webdriver.common.desired_capabilities import DesiredCapabilities

# #指定运行主机与端口号
# driver = webdriver.Remote(command_executor='http://192.168.99.100:4444/wd/hub',
#                           desired_capabilities=DesiredCapabilities.CHROME)
#
# driver.get("http://180.76.60.234/#/my_chat")
#
# time.sleep(1)
#
# driver.get_screenshot_as_file("my_chat_chrome.png")
#
# driver.quit()


import time
from selenium import webdriver
from selenium.webdriver.common.desired_capabilities import DesiredCapabilities

#指定运行主机与端口号
driver = webdriver.Remote(command_executor='http://192.168.99.100:4444/wd/hub',
                          desired_capabilities=DesiredCapabilities.FIREFOX)

driver.get("http://180.76.60.234/#/my_chat")

time.sleep(1)

driver.get_screenshot_as_file("my_chat_firefox.png")

driver.quit()

